package org.jeecg.modules.online.auth.entity;

import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * @Description: online页面权限
 * @Author: jeecg-boot
 * @Date:   2020-07-16
 * @Version: V1.0
 */
@Data
@TableName("onl_auth_page")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="onl_auth_page对象", description="onl_auth_page")
public class OnlAuthPage implements Serializable {
    private static final long serialVersionUID = 1L;

	/** 主键*/
	@TableId(type = IdType.ASSIGN_ID)
    @ApiModelProperty(value = " 主键")
    private java.lang.String id;
	/**online表id*/
	@Excel(name = "online表id", width = 15)
    @ApiModelProperty(value = "online表id")
    private java.lang.String cgformId;
	/**字段名/按钮编码*/
	@Excel(name = "字段名/按钮编码", width = 15)
    @ApiModelProperty(value = "字段名/按钮编码")
    private java.lang.String code;
	/**1字段 2按钮*/
	@Excel(name = "1字段 2按钮", width = 15)
    @ApiModelProperty(value = "1字段 2按钮")
    private java.lang.Integer type;
	/**3可编辑 5可见*/
	@Excel(name = "3可编辑 5可见", width = 15)
    @ApiModelProperty(value = "3可编辑 5可见")
    private java.lang.Integer control;
	/**3列表 5表单*/
	@Excel(name = "3列表 5表单", width = 15)
    @ApiModelProperty(value = "3列表 5表单")
    private java.lang.Integer page;
	/**1有效 0无效*/
	@Excel(name = "1有效 0无效", width = 15)
    @ApiModelProperty(value = "1有效 0无效")
    private java.lang.Integer status;
	/**创建时间*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @ApiModelProperty(value = "创建时间")
    @JsonIgnore
    private java.util.Date createTime;
	/**创建人*/
    @ApiModelProperty(value = "创建人")
    @JsonIgnore
    private java.lang.String createBy;
	/**更新人*/
    @ApiModelProperty(value = "更新人")
    @JsonIgnore
    private java.lang.String updateBy;
	/**更新日期*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @ApiModelProperty(value = "更新日期")
    @JsonIgnore
    private java.util.Date updateTime;

	public OnlAuthPage(){

    }

    /**
     * 构造 字段权限实体 仅用于type=1
     * @param cgformId
     * @param code
     * @param control
     * @param page
     */
    public OnlAuthPage(String cgformId, String code, int page, int control){
	    this.type = 1;
	    this.cgformId = cgformId;
	    this.code = code;
	    this.control = control;
	    this.page = page;
	    this.status = 1;
    }
}
